
<div class="blue ui buttons">
    {{range $i,$k := $.Buttons}}
    <button class="ui button" onclick=eval({{$k.Onclick}})>{{$k.Name}}</button>
    {{end}}
</div>
<table class="ui sortable celled table" id="tables_{{$.Code}}">
    <thead>
        <tr>
            <th class="no-sort">
                <input type="checkbox" id="allcheck_{{$.Code}}" onclick="allcheck('{{$.Code}}')">
            </th>
            {{range $.Heads}}
            <th class="sorted descending">{{.}}</th>
            {{end}}
        </tr>
    </thead>
    <tbody>
        {{ range $i,$j := $.Datas }}
        <tr>
            <td>
                <input type="checkbox" id="{{$.Code}}_check_{{$j.id}}" value="{{$j.id}}">
            </td>
            {{range $n,$m := $.Cols}} {{range $k,$v := $j}} {{if eq $k $m}}
            <td>{{$v}}</td>
            {{end}} {{end}} {{end}}
        </tr>
        {{ end }}
    </tbody>
    <tfoot>
        <tr>
            <th colspan="{{$.Length}}">
                <div class="ui right floated pagination menu">
                    <a class="icon item" onclick="gopage(this,'{{$.Code}}',{{$.BPage}},'')" >
                        <i class="left chevron icon"></i>
                    </a>
                    {{range $i,$k:= $.Pages }}
                    <a class="item {{if eq $k $.Page }} active {{end}}" onclick="gopage(this,'{{$.Code}}',{{$k}},'')" >{{$k}}</a>
                   {{end}}
                    <a class="icon item" onclick="gopage(this,'{{$.Code}}',{{$.APage}},'')">
                        <i class="right chevron icon"></i>
                    </a>
                </div>
            </th>
        </tr>
    </tfoot>
</table>
<script>
$('table').tablesort();
</script>

<div class="ui small modal" id="responsive_{{$.Code}}" style="margin-top: -92px;">
    <div class="header">填写搜索表单 </div>
    <div class="content">
        <form class="ui small form" id="form_responsive_{{$.Code}}">
        {{range $key, $val :=$.Heads}}
            <div class="field ">
                <label>{{$val}}</label>
                <input type="text" id="{{index $.Cols $key}}" name="{{index $.Cols $key}}" value="" placeholder="{{$val}}" >
            </div>
            {{end}}
        </form>
    </div>
    <div class="actions">
        <div class="ui negative button">关闭 </div>
        <div class="ui positive right labeled icon button" onclick="subsearch(this,'{{$.Code}}')">确定 <i class="checkmark icon"></i> </div>
    </div>
</div>


<div class="ui small modal" id="Prompt" style="margin-top: -92px;">
    <div class="header">重要提示 </div>
    <div class="content"><h3>真的要删除吗？</h1></div>
        <div class="actions">
        <div class="ui negative button">关闭 </div>
        <div class="ui positive right labeled icon button" id="delete">确定 <i class="checkmark icon"></i> </div>
    </div>
    </div>